'''
已知一个列表中存储的是员工的出生年份[88,89,90,98,00,99]
由于时间比较久，出生的年份均为2位整数
现需要2为年份前面加19
如果月份是00，将需要加上20
'''
#自己的做法
years1 = [88,89,90,00,99]
years2 =[]
for i in years1:
    if i == 00:
        i = '200'+str(i)
        years2.append(i)
    else:
        i = '19' + str(i)
        years2.append(i)

print("原列表：",years1)
print(years2)
#方法二
for index in range(len(years1)):
    if str(years1[index]) != '0':
        years1[index]='19'+str(years1[index])
    else:
        years1[index] = '200' + str(years1[index])
print(years2)
#方法3
for index,value in enumerate(years1):
    if str(years1[index]) != '0':
        years1[index]='19'+str(value)
    else:
        years1[index] = '200' + str(value)
print(years2)